package com.spzx.product.domain;

import com.spzx.common.core.web.domain.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.Size;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

/**
 * 产品单位对象 product_unit
 */
@Data
@Schema(description = "产品单位")
public class ProductUnit extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 单位名称 */
    @Schema(description = "商品单位名称")
    @NotBlank(message = "商品单位名称不能为空")
    @Size(min = 0,max = 20, message = "商品单位名称不能超过20个字符")
    private String name;
}
